import request from '@/utils/request';
// 请假记录接口
export function getLeaveRecord(params) {
    return request('/api/oa/v1/attendancecount/getleaverecord', {
        method: 'POST',
        data: params
    });
}

// 缺卡记录接口
export function getmylack(params) {
    return request('/api/oa/v1/attendancecount/getmylack', {
        method: 'POST',
        data: params
    });
}

// 迟到早退记录接口
export function getlate(params) {
    return request('/api/oa/v1/attendancecount/getlate', {
        method: 'POST',
        data: params
    });
}

// 缺勤记录接口
export function getabcense(params) {
    return request('/api/oa/v1/attendancecount/getabcense', {
        method: 'POST',
        data: params
    });
}

// 打卡详情接口
export function getMyattenddetail(params) {
    return request('/api/work/v1/attendance/signdetail', {
        method: 'POST',
        data: params
    });
}
// 字典列表接口
export function getTypeList(params) {
    return request('/api/oa/v1/common/select/typelist', {
        method: 'POST',
        params
    });
}

// 迟到早退类型列表
export function getLateTypeList() {
    return request('/api/work/v1/attendance/ruleexception/latelist', {
        method: 'POST'
    });
}
// 请假记录请假类型列表
export function getLeaveTypeList() {
    return request('/api/work/v1/attendance/leavetype/typelistall', {
        method: 'POST'
    });
}
/**
 * 请假记录导出接口
 */
export async function attendLeaveExport(params) {
    // 连接LYH 本机 调试文件下载
    return request('/api/oa/v1/attendancecountexport/getleaverecordexport', {
        method: 'POST',
        data: params,
        getResponse: true,
        encryption: false,
        isFile: true,
        responseType: 'blob',
        headers: { 'Content-Type': 'application/json' }
    });
}
/**
 * 导出缺卡记录
 */
export async function getmylackexport(param) {
    return request('/api/oa/v1/attendancecountexport/getmylackexport', {
        method: 'POST',
        data: param,
        getResponse: true,
        encryption: false,
        isFile: true,
        responseType: 'blob',
        headers: { 'Content-Type': 'application/json' }
    });
}
/**
 * 导出缺勤记录
 */
export async function getmyAbsenceexport(param) {
    return request('/api/oa/v1/attendancecountexport/getmyAbsenceexport', {
        method: 'POST',
        data: param,
        getResponse: true,
        encryption: false,
        isFile: true,
        responseType: 'blob',
        headers: { 'Content-Type': 'application/json' }
    });
}
/**
 * 导出迟到早退记录
 */
export async function getlateexport(param) {
    return request('/api/oa/v1/attendancecountexport/getlateexport', {
        method: 'POST',
        data: param,
        getResponse: true,
        encryption: false,
        isFile: true,
        responseType: 'blob',
        headers: { 'Content-Type': 'application/json' }
    });
}
